package com.ces.knacky.model;

import java.io.Serializable;
import java.util.Date;

import javax.xml.bind.annotation.XmlRootElement;

import org.apache.commons.lang.builder.EqualsBuilder;

import com.ces.knacky.framework.model.AbstractEntity;
import com.ces.knacky.framework.model.AbstractMasterEntity;

/** @author Hibernate CodeGenerator */

@XmlRootElement
public class BidWorkflowAudit extends AbstractMasterEntity implements Serializable {

     /** nullable persistent field */
    private String comments;

    /** persistent field */
    private com.ces.knacky.model.BidWorkflowStatus bidWorkflowStatus;

    /** persistent field */
    private com.ces.knacky.model.Item item;
    
    /** persistent field */
    private com.ces.knacky.model.Bid bid;

    /** full constructor */
    public BidWorkflowAudit(Date createTime, Date updateTime, String comments, com.ces.knacky.model.BidWorkflowStatus bidWorkflowStatus, com.ces.knacky.model.Item item, 
    	com.ces.knacky.model.UserTable user) {
        this.createTime = createTime;
        this.updateTime = updateTime;
        this.comments = comments;
        this.bidWorkflowStatus = bidWorkflowStatus;
        this.item = item;
        this.user = user;
    }

    /** default constructor */
    public BidWorkflowAudit() {
    }

    /** minimal constructor */
    public BidWorkflowAudit(com.ces.knacky.model.BidWorkflowStatus bidWorkflowStatus,
    	com.ces.knacky.model.Item item, com.ces.knacky.model.UserTable user) {
        this.bidWorkflowStatus = bidWorkflowStatus;
        this.item = item;
        this.user = user;
    }

    public String getComments() {
        return this.comments;
    }

    public void setComments(String comments) {
        this.comments = comments;
    }

    public com.ces.knacky.model.BidWorkflowStatus getBidWorkflowStatus() {
        return this.bidWorkflowStatus;
    }

    public void setBidWorkflowStatus(com.ces.knacky.model.BidWorkflowStatus bidWorkflowStatus)
    {
        this.bidWorkflowStatus = bidWorkflowStatus;
    }

    public com.ces.knacky.model.Item getItem() {
        return this.item;
    }

    public void setItem(com.ces.knacky.model.Item item) {
        this.item = item;
    }

    public com.ces.knacky.model.UserTable getUser() {
        return this.user;
    }

    public void setUser(com.ces.knacky.model.UserTable user) {
        this.user = user;
    }

    public boolean equals(Object other) {
        if ( !(other instanceof BidWorkflowAudit) ) return false;
        BidWorkflowAudit castOther = (BidWorkflowAudit) other;
        return new EqualsBuilder()
            .append(this.getId(), castOther.getId())
            .isEquals();
    }

	/**
	 * @return the bid
	 */
	public com.ces.knacky.model.Bid getBid() {
		return bid;
	}

	/**
	 * @param bid the bid to set
	 */
	public void setBid(com.ces.knacky.model.Bid bid) {
		this.bid = bid;
	}
}
